package com.spic.business.riskbase.hierarchy.service.impl;

import java.util.List;
import com.spic.common.core.utils.DateUtils;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.spic.business.riskbase.hierarchy.mapper.RiskDetailsInfoMapper;
import com.spic.business.riskbase.hierarchy.domain.RiskDetailsInfo;
import com.spic.business.riskbase.hierarchy.service.IRiskDetailsInfoService;

/**
 * riskDetailsInfoService业务层处理
 *
 * @author ruoyi
 * @date 2023-04-14
 */
@Service
public class RiskDetailsInfoServiceImpl implements IRiskDetailsInfoService
{
    @Autowired
    private RiskDetailsInfoMapper riskDetailsInfoMapper;

    /**
     * 查询riskDetailsInfo
     *
     * @param id riskDetailsInfo主键
     * @return riskDetailsInfo
     */
    @Override
    public RiskDetailsInfo selectRiskDetailsInfoById(Long id)
    {
        return riskDetailsInfoMapper.selectRiskDetailsInfoById(id);
    }

    /**
     * 查询riskDetailsInfo列表
     *
     * @param riskDetailsInfo riskDetailsInfo
     * @return riskDetailsInfo
     */
    @Override
    public List<RiskDetailsInfo> selectRiskDetailsInfoList(RiskDetailsInfo riskDetailsInfo)
    {
        return riskDetailsInfoMapper.selectRiskDetailsInfoList(riskDetailsInfo);
    }

    /**
     * 新增riskDetailsInfo
     *
     * @param riskDetailsInfo riskDetailsInfo
     * @return 结果
     */
    @Override
    public int insertRiskDetailsInfo(RiskDetailsInfo riskDetailsInfo)
    {
        return riskDetailsInfoMapper.insertRiskDetailsInfo(riskDetailsInfo);
    }

    /**
     * 修改riskDetailsInfo
     *
     * @param riskDetailsInfo riskDetailsInfo
     * @return 结果
     */
    @Override
    public int updateRiskDetailsInfo(RiskDetailsInfo riskDetailsInfo)
    {
        return riskDetailsInfoMapper.updateRiskDetailsInfo(riskDetailsInfo);
    }

    /**
     * 批量删除riskDetailsInfo
     *
     * @param ids 需要删除的riskDetailsInfo主键
     * @return 结果
     */
    @Override
    public int deleteRiskDetailsInfoByIds(Long[] ids)
    {
        return riskDetailsInfoMapper.deleteRiskDetailsInfoByIds(ids);
    }

    /**
     * 删除riskDetailsInfo信息
     *
     * @param id riskDetailsInfo主键
     * @return 结果
     */
    @Override
    public int deleteRiskDetailsInfoById(Long id)
    {
        return riskDetailsInfoMapper.deleteRiskDetailsInfoById(id);
    }

    @Override
    public int deleteRiskDetailsByRiskAnalyse(Long id) {
        return riskDetailsInfoMapper.deleteRiskDetailsByRiskAnalyse();
    }

    @Override
    public int batchRiskDetailsInfo(List<RiskDetailsInfo> list) {
        return riskDetailsInfoMapper.batchRiskDetailsInfo(list);
    }
}
